<template>
  <div >
    <i class="fa fa-chevron-left" @click="home"></i>
    <h1>{{list.name}}</h1>
    <div v-html="list.content"></div>
  </div>
</template>

<script>
import axios from 'axios'

export default {
   data(){
    return{
        list:{}
    }
   },
  async created(){
   const res=await axios.get("http://localhost:1337/api/v1/products/"+this.$route.params.id)
   this.list=res.data.data;
   },
   methods:{
    home(){
        this.$router.go(-1)
    }
   }
}
</script>

<style scoped>
   
</style>